package com.japp.manager.mapper;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.japp.base.BaseMapper;
import com.japp.manager.bean.CustomerBean;
import com.japp.manager.bean.CustomerInfoBean;
/**
 * 客户管理
 * @author Jion
 *
 */
public interface CustomerMapper extends BaseMapper<CustomerBean> {

	CustomerBean findCustomerById(@Param("id")int id);
	
	int insertCustomer(@Param("customer")CustomerBean customer);
	
	int deleteCustomerById(@Param("keys")String[] keys);
	
	int updateCustomer(@Param("customer")CustomerBean customer);
	
	/****** 服务计划开始******/
	List<CustomerInfoBean> findCustomerInfoByCId(@Param("id")int id);
	
	List<CustomerInfoBean> findCustomerInfoById(@Param("id")int id);
	
	int insertCustomerInfo(@Param("cid")int cid,@Param("list")List<CustomerInfoBean> list);
	
	int deleteCustomerInfoByCid(@Param("keys")String[] keys);
	/**
	 * 删除计划类型
	 * @param cid
	 * @return
	 */
	int deleteCustomerInfoTypeByCid(@Param("cid")int cid,@Param("type")int type);
	
	int deleteCustomerInfoById(@Param("keys")String[] keys);
	
	int updateCustomerInfo(@Param("customerInfo")CustomerInfoBean customerInfo );
	/****** 服务计划结束******/
	
	
}
